Revert previous change (commit mistake).
authorChong Yidong <cyd@stupidchicken.com>
Sat, 10 Jan 2009 13:06:23 +0000 (13:06 +0000)
committerChong Yidong <cyd@stupidchicken.com>
Sat, 10 Jan 2009 13:06:23 +0000 (13:06 +0000)
lisp/frame.el

index e886a5179285cd14b8a0d087b14c69254b7300bd..c34e5d361f23d0fdb859f35a9859210be259cdb4 100644 (file)
@@ -648,6 +648,23 @@ The optional argument PARAMETERS specifies additional frame parameters."
         (make-frame `((window-system . x)
                       (display . ,display) . ,parameters)))))
 
+(defun make-frame-on-tty (tty type &optional parameters)
+  "Make a frame on terminal device TTY.
+TTY should be the file name of the tty device to use.  TYPE
+should be the terminal type string of TTY, for example \"xterm\"
+or \"vt100\".  The optional third argument PARAMETERS specifies
+additional frame parameters."
+  ;; Use "F" rather than "f", in case the device does not exist, as
+  ;; far as the filesystem is concerned.
+  (interactive "FOpen frame on tty device: \nsTerminal type of %s: ")
+  (unless tty
+    (error "Invalid terminal device"))
+  (unless type
+    (error "Invalid terminal type"))
+  (if (eq window-system 'pc)
+      (make-frame `((window-system . pc) (tty . ,tty) (tty-type . ,type) . ,parameters))
+    (make-frame `((window-system . nil) (tty . ,tty) (tty-type . ,type) . ,parameters))))
+
 (declare-function x-close-connection "xfns.c" (terminal))
 
 (defun close-display-connection (display)